import { DEFAULT_LAYOUT } from '../base';
import { AppRouteRecordRaw } from '../types';

const GROUP: AppRouteRecordRaw = {
  path: '/group',
  name: 'group',
  component: DEFAULT_LAYOUT,
  meta: {
    locale: 'menu.group',
    requiresAuth: true,
    icon: 'icon-relation',
    order: 12,
  },
  children: [
    {
      path: 'course', // The midline path complies with SEO specifications
      name: 'Course',
      component: () => import('@/views/group/course/index.vue'),
      meta: {
        locale: 'menu.group.course',
        requiresAuth: true,
        roles: ['*'],
      },
    },
    {
      path: 'groupInfo',
      name: 'GroupInfo',
      component: () => import('@/views/group/info/index.vue'),
      meta: {
        locale: 'menu.group.info',
        requiresAuth: true,
        roles: ['*'],
      },
    },
  ],
};

export default GROUP;
